package result

import (
	"github.com/beego/beego/v2/server/web/context"
)

const (
	HTTPContentType     = "Content-Type"
	MIMEApplicationJSON = "application/json"
)

func HttpResponse(statusCode int, body []byte, ctx *context.Context) {
	ctx.Output.SetStatus(statusCode)
	ctx.Output.Header(HTTPContentType, MIMEApplicationJSON)
	ctx.Output.Body(body)
}
